<template>
  <div>
    <h3>{{ $t('xxx') }}</h3>
    <button @click="btnClick">切换语言</button>
  </div>
</template>

<script>
export default {
  methods: {
    btnClick () {
      this.$i18n.locale = this.$i18n.locale === 'zh' ? 'en' : 'zh'
    }
  }
}
</script>

<style></style>
